using System;
using System.Collections.Generic;
using System.Text;

namespace ClientTools.Client.Library.Settings
{
    [Serializable]
    public class ClientTools
    {
        private List<Profile> _Profiles = new List<Profile>();

        public List<Profile> Profiles
        {
            get { return _Profiles; }
            set { _Profiles = value; }
        }

        public void DeleteProfile(Profile profile) 
        {
            this.Profiles.Remove(profile);
        }

        public Settings.Profile AddNewProfile()
        {
            Settings.Profile profile = new Profile();
            profile.ProfileName = "New profile - please rename";
            profile.ProviderName = Client.Library.Provider.ProviderManager.ProviderInfos[0].ProviderName;
            profile.ServiceFolderUrl = "http://www.yourdomain.com/webservices/";
            //profile.PackagerServiceUrl = "http://www.yourdomain.com/webservices/ClientToolsPackageService.asmx";
            profile.DbConnectionString = "Server=SERVER;Database=DATABASENAME;User ID=USERNAME;Password=PASSWORD;Trusted_Connection=False";
            profile.UmbracoPassword = "";
            profile.UmbracoUserName = "UmbracoUsername";

            this.Profiles.Add(profile);
            return profile;
        }
    }
}
